package cn.wcy.design_patterns.creationtype01.abstractfactory02;


import cn.wcy.design_patterns.creationtype01.abstractfactory02.impl.EGMCacheServiceImpl;

public class ApiTest {

    public static void main(String[] args) {
        CacheService proxy_EGM = Factory.getInvokeStrategy(EGMCacheServiceImpl.class.getSimpleName());
        proxy_EGM.set("user_name_01", "小傅哥");
        String val01 = proxy_EGM.get("user_name_01");
        System.out.println("测试结果：" + val01);

     /*   CacheService proxy_IIR = JDKProxy.getProxy(CacheServiceImpl.class, new IIRCacheAdapter());
        proxy_IIR.set("user_name_01", "小傅哥");
        String val02 = proxy_IIR.get("user_name_01");
        System.out.println("测试结果：" + val02);*/
    }

}
